<%--
  Created by Cweili on 13-9-17.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java"  pageEncoding="utf-8"
         trimDirectiveWhitespaces="true" isELIgnored="false" %>
<%@ taglib prefix="t" tagdir="/WEB-INF/tags" %>
<t:html>
	<t:head />
	<t:body>
		<t:navbar />
		<t:panel>
			<div class="panel-heading">
				<h3>
					${title}管理
					<div class="btn-group">
						<button class="btn btn-primary new" data-toggle="modal" data-target="#editorModal"><t:icon>plus</t:icon></button>
						<button class="btn btn-danger del" onclick="del()"><t:icon>trash</t:icon></button>
					</div>
				</h3>
			</div>
			<t:datatable id="list">
				<th width="28px"><input type="checkbox" class="check-all"></th>
				<th>账户</th>
				<th>姓名</th>
				<th>管理员</th>
				<th width="66px"><t:icon>edit</t:icon></th>
			</t:datatable>
		</t:panel>
		<t:editor title="${title}">
			<t:formgroup name="account" label="账户">
				<input type="text" class="form-control" id="account" name="account" placeholder="使用账户名进行登录，必填">
			</t:formgroup>
			<t:formgroup name="name" label="姓名">
				<input type="text" class="form-control" id="name" name="name" placeholder="必填">
			</t:formgroup>
			<t:formgroup name="password" label="密码">
				<input type="text" class="form-control" id="password" name="password" placeholder="留空则不修改">
			</t:formgroup>
			<t:formgroup name="admin" label="管理员">
				<input type="hidden" id="admin" name="admin">
				<div class="btn-group">
					<button class="btn btn-success btn-admin-false">否</button>
					<button class="btn btn-warning btn-admin-true">是</button>
				</div>
			</t:formgroup>
		</t:editor>
		<t:delconfirm name="选中${title}" />
		<t:template id="listTpl">
			<td><input type="checkbox" name="idCheckbox" value="'$id'"></td>
			<td>'$account'</td>
			<td>'$name'</td>
			<td>'$adminStatus'</td>
			<td>'$operatorTemplate'</td>
		</t:template>
	</t:body>
</t:html>
